using System;
using System.Collections.Generic;
using System.Text;

namespace EBookReader.Library.Config
{
    [Serializable]
    public class EBookWebsite
    {
        [NonSerialized]
        private string name;
        [NonSerialized]
        private string intro;
        [NonSerialized]
        private string url;
        [NonSerialized]
        private string encode;
        [NonSerialized]
        private string type;
        [NonSerialized]
        private string infoRegex;
        [NonSerialized]
        private string titleRegex;
        [NonSerialized]
        private List<string> titleEncodeRegex;
        [NonSerialized]
        private string contentRegex;
        [NonSerialized]
        private List<string> contentEncodeRegex;

        public EBookWebsite()
        {
            name = string.Empty;
            intro = string.Empty;
            url = string.Empty;
            infoRegex = string.Empty;
            encode = "GBK";
            type = "none";
            titleRegex = string.Empty;
            titleEncodeRegex = new List<string>();
            contentRegex = string.Empty;
            contentEncodeRegex = new List<string>();
        }

        public string Name
        {
            get { return name; }
            set { name = value; }
        }

        public string Intro
        {
            get { return intro; }
            set { intro = value; }
        }

        public string Url
        {
            get { return url; }
            set { url = value; }
        }

        public string Encode
        {
            get { return encode; }
            set { encode = value; }
        }

        public string Type
        {
            get { return type; }
            set { type = value; }
        }

        public string InfoRegex
        {
            get { return infoRegex; }
            set { infoRegex = value; }
        }

        public string TitleRegex
        {
            get { return titleRegex; }
            set { titleRegex = value; }
        }

        public List<string> TitleEncodeRegex
        {
            get { return titleEncodeRegex; }
            set { titleEncodeRegex = value; }
        }

        public string ContentRegex
        {
            get { return contentRegex; }
            set { contentRegex = value; }
        }

        public List<string> ContentEncodeRegex
        {
            get { return contentEncodeRegex; }
            set { contentEncodeRegex = value; }
        }
    }
}
